package cml.coding;

import java.io.File;
import java.io.FileNotFoundException;
import java.io.PrintWriter;
import java.io.UnsupportedEncodingException;

public class CodeWriter {
	
	private PrintWriter pw;
	
	public CodeWriter(String code) throws FileNotFoundException, UnsupportedEncodingException {
		
		File f = new File(code);
		pw = new PrintWriter(f, "Cp1252");
	}
	
	public void writeToFile(String s) {
		
		pw.write(s);
	}
	
	public void closeFile() {
		
		pw.close();
	}
}
